package com.ruoyi.passengers.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.passengers.mapper.ConsumptionInformationMapper;
import com.ruoyi.passengers.domain.ConsumptionInformation;
import com.ruoyi.passengers.service.IConsumptionInformationService;

/**
 * 消费信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-08-17
 */
@Service
public class ConsumptionInformationServiceImpl implements IConsumptionInformationService 
{
    @Autowired
    private ConsumptionInformationMapper consumptionInformationMapper;

    /**
     * 查询消费信息
     * 
     * @param id 消费信息主键
     * @return 消费信息
     */
    @Override
    public ConsumptionInformation selectConsumptionInformationById(Long id)
    {
        return consumptionInformationMapper.selectConsumptionInformationById(id);
    }

    /**
     * 查询消费信息列表
     * 
     * @param consumptionInformation 消费信息
     * @return 消费信息
     */
    @Override
    public List<ConsumptionInformation> selectConsumptionInformationList(ConsumptionInformation consumptionInformation)
    {
        return consumptionInformationMapper.selectConsumptionInformationList(consumptionInformation);
    }

    /**
     * 新增消费信息
     * 
     * @param consumptionInformation 消费信息
     * @return 结果
     */
    @Override
    public int insertConsumptionInformation(ConsumptionInformation consumptionInformation)
    {
        return consumptionInformationMapper.insertConsumptionInformation(consumptionInformation);
    }

    /**
     * 修改消费信息
     * 
     * @param consumptionInformation 消费信息
     * @return 结果
     */
    @Override
    public int updateConsumptionInformation(ConsumptionInformation consumptionInformation)
    {
        return consumptionInformationMapper.updateConsumptionInformation(consumptionInformation);
    }

    /**
     * 批量删除消费信息
     * 
     * @param ids 需要删除的消费信息主键
     * @return 结果
     */
    @Override
    public int deleteConsumptionInformationByIds(Long[] ids)
    {
        return consumptionInformationMapper.deleteConsumptionInformationByIds(ids);
    }

    /**
     * 删除消费信息信息
     * 
     * @param id 消费信息主键
     * @return 结果
     */
    @Override
    public int deleteConsumptionInformationById(Long id)
    {
        return consumptionInformationMapper.deleteConsumptionInformationById(id);
    }
}
